#include<stdio.h>
int main()
{
    unsigned long long int a=1,sum=0;//a是阶乘，sum是阶乘和
    int i=1,j=1;
    for (;i<=20;i++)
    {j=1;a=1;
        for (;j<=i;j++)
        {
            a=a*j;
        }
        sum=sum+a;
    }
    printf("sum=%llu",sum);
    return 0;
}